package com.ywk.wsServer;

import java.util.Scanner;

/**
 * @Author zbh
 * @Date 2023/5/4
 */
public class WSServerMain {
    public static void main(String[] args) {
        WsServer wsServer = new WsServer(8888);
        wsServer.start();

        Scanner scanner = new Scanner(System.in);
        while (scanner.hasNext()) {
            String s = scanner.nextLine();
            if ("exit".equals(s)){
                break;
            }
            wsServer.broadcast(s);
        }
    }
}
